vscsiif: allow larger segments-per-request values
authorJan Beulich <jbeulich@suse.com>
Thu, 13 Dec 2012 10:22:54 +0000 (11:22 +0100)
committerJan Beulich <jbeulich@suse.com>
Thu, 13 Dec 2012 10:22:54 +0000 (11:22 +0100)
commitd27df538094f2fc5188de0b66538eaf3e3e85fad
tree1620b5569ccd4e8f3b4b756a38fc77e50cadb000
parente7c5674950f0496523dbb5cc46e9c53d199c79ee
vscsiif: allow larger segments-per-request values

At least certain tape devices require fixed size blocks to be operated
upon, i.e. breaking up of I/O requests is not permitted. Consequently
we need an interface extension that (leaving aside implementation
limitations) doesn't impose a limit on the number of segments that can
be associated with an individual request.

This, in turn, excludes the blkif extension FreeBSD folks implemented,
as that still imposes an upper limit (the actual I/O request still
specifies the full number of segments - as an 8-bit quantity -, and
subsequent ring slots get used to carry the excess segment
descriptors).

The alternative therefore is to allow the frontend to pre-set segment
descriptors _before_ actually issuing the I/O request. I/O will then
be done by the backend for the accumulated set of segments.

To properly associate segment preset operations with the main request,
the rqid-s between them should match (originally I had hoped to use
this to avoid producing individual responses for the pre-set
operations, but that turned out to violate the underlying shared ring
implementation).

Negotiation of the maximum number of segments a particular backend
implementation supports happens through a new "segs-per-req" xenstore
node.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
xen/include/public/io/vscsiif.h